<!--新建班车页-->
<template>
    <el-container class="layout-container">
        <el-header class="layout-header">
            <div>
                <el-button type="primary" @click="handleSave">保存</el-button>
            </div>
        </el-header>
        <el-main class="layout-main">
            <div class="subfield-layout">
                <div class="subfield-wrap">
                    <div class="subfield-title">信息</div>
                    <div class="subfield-main">
                        <div class="subfield-content">
                            <m-form ref="formRef" :fields="fieldList" ></m-form>
                        </div>
                    </div>
                </div>
            </div>

        </el-main>

       <!-- <el-footer class="layout-footer">
            <div></div>
        </el-footer>-->

    </el-container>
</template>

<script setup>
  import {ref} from 'vue';
  import MForm from '@/components/common/Form/Form'
  import MSubmodule from '@/components/Submodule/Submodule'

  const fieldList = ref([
    {label: '班车编号',field_id: 'shuttle_id',type: 'text',col: 2,disabled:true},
    {label: '班车名称',field_id: 'shuttle_name',type: 'text',col: 2},
    {label: '套票标签编号',field_id: 'packag_label_id',type: 'reference',col: 2,disabled:true},
    {label: '套票标签名称',field_id: 'packag_label_name',type: 'reference',col: 2},
    {label: '站点编号',field_id: 'school_id',type: 'reference',col: 2},
    {label: '站点名称',field_id: 'school_name',type: 'reference',col: 2},
    {label: '说明',field_id: 'mark',type: 'textarea',col: 4},
    {label: '座位总数',field_id: 'seat_total',type: 'number',col: 2,precision: 4},
    {label: '班车座位表编号',field_id: 'shuttle_seat_id',type: 'reference',col: 2,required: true},
    {label: '班车座位表名称',field_id: 'shuttle_seat_name',type: 'reference',col: 2},
    {label: '开售时间起',field_id: 'sell_dateime_start',type: 'datetime',col: 2,disabled:true},
    {label: '开售时间止',field_id: 'sell_dateime_end',type: 'datetime',col: 2},
    {label: '班车有效时间起',field_id: 'effective_time_start',type: 'datetime',col: 2},
    {label: '班车有效时间止',field_id: 'effective_time_end',type: 'datetime',col: 2},
    {label: '营运组编号',field_id: 'operation_group_id',type: 'reference',col: 2},
    {label: '营运组名称',field_id: 'operation_group_name',type: 'reference',col: 2},
    {label: '使用标识',field_id: 'is_used',type: 'bool',col: 2, disabled: true},
    {label: '测试',field_id: 'ceshi',type: 'picklist',col: 2,options: [{label:1,value:2}], disabled: true},
  ]),
    formRef = ref(null)

    function handleChange() {

    }
    function handleSave() {
      console.log(formRef.value.data);
    }
</script>

<style scoped lang="less">
    @import '../../assets/css/pageDtl.less';

</style>
